<table id="ths">
    <thead>
        <tr>
            <th>${message(code: 'moc.th.id.label', default: 'Id')}</th>
            <th><g:message code="moc.te.te001.label" default="Te001" /></th>
            <th><g:message code="moc.te.te003.label" default="Te003" /></th>
            <th>${message(code: 'moc.th.th001.label', default: 'Th001')}</th>
            <th>${message(code: 'moc.th.th002.label', default: 'Th002')}</th>
            <th>${message(code: 'moc.th.th003.label', default: 'Th003')}</th>
            <th><g:message code="moc.th.tc.label" default="Tc" /></th>
        </tr>
    </thead>
    <tbody>
    <g:each in="${thInstanceList}" status="i" var="thInstance">
        <tr class="${(i % 2) == 0 ? 'odd' : 'even'}">
            <td><g:link controller="th" action="edit" id="${thInstance.id}">${fieldValue(bean: thInstance, field: "id")}</g:link></td>
            <td>${fieldValue(bean: thInstance, field: "te.te001")}</td>
            <td>${fieldValue(bean: thInstance, field: "te.te003")}</td>
            <td id="${thInstance.id}" name="th001">${fieldValue(bean: thInstance, field: "th001")}</td>
            <td>${fieldValue(bean: thInstance, field: "th002")}</td>
            <td><g:formatNumber number="${thInstance.th003}" format="###,##0.00" /></td>
            <td>${fieldValue(bean: thInstance, field: "tc.tc001")}</td>
        </tr>
    </g:each>
    </tbody>
</table>